using Google.ProtocolBuffers;
using micromsg.Proto;
using System;
using System.CodeDom.Compiler;
using System.Diagnostics;
using System.IO;
using System.Runtime.CompilerServices;
namespace micromsg
{
	[GeneratedCode("ProtoGen", "2.3.0.277"), DebuggerNonUserCode, CompilerGenerated]
	public sealed class GmailInfo : GeneratedMessageLite<GmailInfo, GmailInfo.Builder>
	{
		[GeneratedCode("ProtoGen", "2.3.0.277"), DebuggerNonUserCode, CompilerGenerated]
		public sealed class Builder : GeneratedBuilderLite<GmailInfo, GmailInfo.Builder>
		{
			private bool resultIsReadOnly;
			private GmailInfo result;
			protected override GmailInfo.Builder ThisBuilder
			{
				get
				{
					return this;
				}
			}
			public override bool IsInitialized
			{
				get
				{
					return this.result.IsInitialized;
				}
			}
			protected override GmailInfo MessageBeingBuilt
			{
				get
				{
					return this.PrepareBuilder();
				}
			}
			public override GmailInfo DefaultInstanceForType
			{
				get
				{
					return GmailInfo.DefaultInstance;
				}
			}
			public string GmailAcct
			{
				get
				{
					return this.result.GmailAcct;
				}
				set
				{
					this.SetGmailAcct(value);
				}
			}
			public uint GmailSwitch
			{
				get
				{
					return this.result.GmailSwitch;
				}
				set
				{
					this.SetGmailSwitch(value);
				}
			}
			public uint GmailErrCode
			{
				get
				{
					return this.result.GmailErrCode;
				}
				set
				{
					this.SetGmailErrCode(value);
				}
			}
			public Builder()
			{
				this.result = GmailInfo.DefaultInstance;
				this.resultIsReadOnly = true;
			}
			internal Builder(GmailInfo cloneFrom)
			{
				this.result = cloneFrom;
				this.resultIsReadOnly = true;
			}
			private GmailInfo PrepareBuilder()
			{
				if (this.resultIsReadOnly)
				{
					GmailInfo other = this.result;
					this.result = new GmailInfo();
					this.resultIsReadOnly = false;
					this.MergeFrom(other);
				}
				return this.result;
			}
			public override GmailInfo.Builder Clear()
			{
				this.result = GmailInfo.DefaultInstance;
				this.resultIsReadOnly = true;
				return this;
			}
			public override GmailInfo.Builder Clone()
			{
				if (this.resultIsReadOnly)
				{
					return new GmailInfo.Builder(this.result);
				}
				return new GmailInfo.Builder().MergeFrom(this.result);
			}
			public override GmailInfo BuildPartial()
			{
				if (this.resultIsReadOnly)
				{
					return this.result;
				}
				this.resultIsReadOnly = true;
				return this.result.MakeReadOnly();
			}
			public override GmailInfo.Builder MergeFrom(IMessageLite other)
			{
				if (other is GmailInfo)
				{
					return this.MergeFrom((GmailInfo)other);
				}
				base.MergeFrom(other);
				return this;
			}
			public override GmailInfo.Builder MergeFrom(GmailInfo other)
			{
				return this;
			}
			public override GmailInfo.Builder MergeFrom(ICodedInputStream input)
			{
				return this.MergeFrom(input, ExtensionRegistry.Empty);
			}
			public override GmailInfo.Builder MergeFrom(ICodedInputStream input, ExtensionRegistry extensionRegistry)
			{
				this.PrepareBuilder();
				uint num;
				string text;
				while (input.ReadTag(out num, out text))
				{
					if (num == 0u && text != null)
					{
						int num2 = Array.BinarySearch<string>(GmailInfo._gmailInfoFieldNames, text, StringComparer.get_Ordinal());
						if (num2 < 0)
						{
							this.ParseUnknownField(input, extensionRegistry, num, text);
							continue;
						}
						num = GmailInfo._gmailInfoFieldTags[num2];
					}
					uint num3 = num;
					if (num3 <= 10u)
					{
						if (num3 == 0u)
						{
							throw InvalidProtocolBufferException.InvalidTag();
						}
						if (num3 == 10u)
						{
							this.result.hasGmailAcct = input.ReadString(ref this.result.gmailAcct_);
							continue;
						}
					}
					else
					{
						if (num3 == 16u)
						{
							this.result.hasGmailSwitch = input.ReadUInt32(ref this.result.gmailSwitch_);
							continue;
						}
						if (num3 == 24u)
						{
							this.result.hasGmailErrCode = input.ReadUInt32(ref this.result.gmailErrCode_);
							continue;
						}
					}
					if (WireFormat.IsEndGroupTag(num))
					{
						return this;
					}
					this.ParseUnknownField(input, extensionRegistry, num, text);
				}
				return this;
			}
			public GmailInfo.Builder SetGmailAcct(string value)
			{
				ThrowHelper.ThrowIfNull(value, "value");
				this.PrepareBuilder();
				this.result.hasGmailAcct = true;
				this.result.gmailAcct_ = value;
				return this;
			}
			public GmailInfo.Builder ClearGmailAcct()
			{
				this.PrepareBuilder();
				this.result.hasGmailAcct = false;
				this.result.gmailAcct_ = "";
				return this;
			}
			public GmailInfo.Builder SetGmailSwitch(uint value)
			{
				this.PrepareBuilder();
				this.result.hasGmailSwitch = true;
				this.result.gmailSwitch_ = value;
				return this;
			}
			public GmailInfo.Builder ClearGmailSwitch()
			{
				this.PrepareBuilder();
				this.result.hasGmailSwitch = false;
				this.result.gmailSwitch_ = 0u;
				return this;
			}
			public GmailInfo.Builder SetGmailErrCode(uint value)
			{
				this.PrepareBuilder();
				this.result.hasGmailErrCode = true;
				this.result.gmailErrCode_ = value;
				return this;
			}
			public GmailInfo.Builder ClearGmailErrCode()
			{
				this.PrepareBuilder();
				this.result.hasGmailErrCode = false;
				this.result.gmailErrCode_ = 0u;
				return this;
			}
		}
		public const int GmailAcctFieldNumber = 1;
		public const int GmailSwitchFieldNumber = 2;
		public const int GmailErrCodeFieldNumber = 3;
		private static readonly GmailInfo defaultInstance;
		private static readonly string[] _gmailInfoFieldNames;
		private static readonly uint[] _gmailInfoFieldTags;
		private bool hasGmailAcct;
		private string gmailAcct_ = "";
		private bool hasGmailSwitch;
		private uint gmailSwitch_;
		private bool hasGmailErrCode;
		private uint gmailErrCode_;
		private int memoizedSerializedSize = -1;
		public static GmailInfo DefaultInstance
		{
			get
			{
				return GmailInfo.defaultInstance;
			}
		}
		public override GmailInfo DefaultInstanceForType
		{
			get
			{
				return GmailInfo.DefaultInstance;
			}
		}
		protected override GmailInfo ThisMessage
		{
			get
			{
				return this;
			}
		}
		public string GmailAcct
		{
			get
			{
				return this.gmailAcct_;
			}
		}
		public uint GmailSwitch
		{
			get
			{
				return this.gmailSwitch_;
			}
		}
		public uint GmailErrCode
		{
			get
			{
				return this.gmailErrCode_;
			}
		}
		public override bool IsInitialized
		{
			get
			{
				return this.hasGmailSwitch && this.hasGmailErrCode;
			}
		}
		public override int SerializedSize
		{
			get
			{
				int num = this.memoizedSerializedSize;
				if (num != -1)
				{
					return num;
				}
				num = 0;
				if (this.hasGmailAcct)
				{
					num += CodedOutputStream.ComputeStringSize(1, this.GmailAcct);
				}
				if (this.hasGmailSwitch)
				{
					num += CodedOutputStream.ComputeUInt32Size(2, this.GmailSwitch);
				}
				if (this.hasGmailErrCode)
				{
					num += CodedOutputStream.ComputeUInt32Size(3, this.GmailErrCode);
				}
				this.memoizedSerializedSize = num;
				return num;
			}
		}
		private GmailInfo()
		{
		}
		public override void WriteTo(ICodedOutputStream output)
		{
			int arg_06_0 = this.SerializedSize;
			string[] gmailInfoFieldNames = GmailInfo._gmailInfoFieldNames;
			if (this.hasGmailAcct)
			{
				output.WriteString(1, gmailInfoFieldNames[0], this.GmailAcct);
			}
			if (this.hasGmailSwitch)
			{
				output.WriteUInt32(2, gmailInfoFieldNames[2], this.GmailSwitch);
			}
			if (this.hasGmailErrCode)
			{
				output.WriteUInt32(3, gmailInfoFieldNames[1], this.GmailErrCode);
			}
		}
		public override int GetHashCode()
		{
			int num = base.GetType().GetHashCode();
			if (this.hasGmailAcct)
			{
				num ^= this.gmailAcct_.GetHashCode();
			}
			if (this.hasGmailSwitch)
			{
				num ^= this.gmailSwitch_.GetHashCode();
			}
			if (this.hasGmailErrCode)
			{
				num ^= this.gmailErrCode_.GetHashCode();
			}
			return num;
		}
		public override bool Equals(object value)
		{
			GmailInfo gmailInfo = value as GmailInfo;
			return gmailInfo != null && (this.hasGmailAcct == gmailInfo.hasGmailAcct && (!this.hasGmailAcct || this.gmailAcct_.Equals(gmailInfo.gmailAcct_))) && (this.hasGmailSwitch == gmailInfo.hasGmailSwitch && (!this.hasGmailSwitch || this.gmailSwitch_.Equals(gmailInfo.gmailSwitch_))) && (this.hasGmailErrCode == gmailInfo.hasGmailErrCode && (!this.hasGmailErrCode || this.gmailErrCode_.Equals(gmailInfo.gmailErrCode_)));
		}
		public override void PrintTo(TextWriter writer)
		{
			GeneratedMessageLite<GmailInfo, GmailInfo.Builder>.PrintField("GmailAcct", this.hasGmailAcct, this.gmailAcct_, writer);
			GeneratedMessageLite<GmailInfo, GmailInfo.Builder>.PrintField("GmailSwitch", this.hasGmailSwitch, this.gmailSwitch_, writer);
			GeneratedMessageLite<GmailInfo, GmailInfo.Builder>.PrintField("GmailErrCode", this.hasGmailErrCode, this.gmailErrCode_, writer);
		}
		public static GmailInfo ParseFrom(byte[] data)
		{
			return GmailInfo.CreateBuilder().MergeFrom(data).BuildParsed();
		}
		private GmailInfo MakeReadOnly()
		{
			return this;
		}
		public static GmailInfo.Builder CreateBuilder()
		{
			return new GmailInfo.Builder();
		}
		public override GmailInfo.Builder ToBuilder()
		{
			return GmailInfo.CreateBuilder(this);
		}
		public override GmailInfo.Builder CreateBuilderForType()
		{
			return new GmailInfo.Builder();
		}
		public static GmailInfo.Builder CreateBuilder(GmailInfo prototype)
		{
			return new GmailInfo.Builder(prototype);
		}
		static GmailInfo()
		{
			GmailInfo.defaultInstance = new GmailInfo().MakeReadOnly();
			GmailInfo._gmailInfoFieldNames = new string[]
			{
				"GmailAcct",
				"GmailErrCode",
				"GmailSwitch"
			};
			GmailInfo._gmailInfoFieldTags = new uint[]
			{
				10u,
				24u,
				16u
			};
			object.ReferenceEquals(micromsg.Proto.GmailInfo.Descriptor, null);
		}
	}
}
